import os
import glob
import sys

path = sys.argv[1]

complexities = []
for (i, infile) in enumerate(glob.glob(os.path.join(path, '*.png'))):
    p = os.popen('./complexity {0}'.format(infile), "r")
    complexities.append(float(p.readline().strip()))

print complexities
